package com.lixixi.tingshu.album.config;

import com.lixixi.tingshu.album.properties.VodProperties;
import com.qcloud.vod.VodUploadClient;
import jakarta.annotation.Resource;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class VodConfig {
	@Resource
	VodProperties vodProperties;

	@Bean
	VodUploadClient vodUploadClient() {
		//初始化一个上传客户端对象
		//使用云 API 密钥初始化 VodUploadClient 实例。
		return new VodUploadClient(vodProperties.getSecretId()
				, vodProperties.getSecretKey());
	}
}
